" +"forearm, thumb, wrist, knuckle, palm
" +"middle, pinky, index, ring
" +"dinner bell dinner bell ding") QAUTHOR='They Might Be Giants, "Dinner Bell"'> <* ** macro to format an explanation *> <$MACRO explan TITLE:string/r NAME:string ONLYDEFTAG:bool> <** create named reference **> <$IF COND=(SET NAME)> <$ELSE>
<** create heading **> <(title)> <$IF COND=(ONLYDEFTAG)> (for use within only)
<* ** macro to format example for IGNORE *> <$MACRO exmp_ign VALUE:string/r>
<(value)>
This section covers which options and switches you can pass to , and which exit codes are returned to CLI.

General rules for options

As is an tool developed under AmigaOS and I never liked the cryptic "cmd -cvf -osepp.x"-way of invoking commands comming from Unix, uses a syntax like most commands of AmigaOS; even for ports on other operating-systems. ( AmigaOS provides an OS-function called ReadArgs() for argument-parsing.)

All options and swiches are case-insensitive. If you start without any options, a short help message will be displayed.

Options can be followed by modifiers, which specify things such as the type of the option. Modifiers are specified by following the option with a '/' and a single character modifier. Multiple modifiers can be specified by using multiple '/'s. Valid modifiers are:

/S - Switch.
This is considered a boolean variable, and will be set if the option name appears in the command-line.
/K - Keyword.
This means that the option will not be filled unless the keyword appears. For example if the template is Name/K, then unless Name={string} or Name {string} appears in the command line, Name will not be filled.
/N - Number.
This parameter is considered a decimal number. If an invalid number is specified, an error will be returned. <* /T - Toggle. This is similar to a switch, but when specified causes the boolean value to "toggle". Similar to /S.*>
/A - Required.
This keyword must be given a value during command-line processing, or an error is returned. <* /F - Rest of line. If this is specified, the entire rest of the line is taken as the parameter for the option, even if other option keywords appear in it.*>
/M - Multiple strings.
This means the argument will take any number strings. Any arguments not considered to be part of another option will be added to this option.

Options

Specifies the input filename. To use as input file, the pseudo filename STDIN (case sensitive) should be specified. If you specify more than one file, the last file is taken as main source, and all previous files are included before it. This is useful to include macro-definitions within the command-line instead of an in the hsc-source. Specifies the output filename or the destination directory. If the argument ends with a "/" (or also ":"), it is interpreted as a directory. In this case, the name of the outputfile is created from the name of the input file, with an extension specified (see below). If no output file is set, is used instead.
For details, read the seaction about File Options If you specify a directory for output, the output-filename will depend on the input-filename and the extension specified with this options. If you do not set an extension, "html" will be used. A will be added automatically. Setting EXTENSION=. will ommit this and result into exactly the same filename as the input. If you specify a complete filename for output, this option has no effect. Redirects messages to a file. By default, ist used. Describes how messages should be displayed. Legal placeholders are:
        %f      filename
        %x, %y  location in file (column, line)
        %c      message class
        %i      message id (numeric)
        %m      message text
        %n      inserts a linefeed
    
Example: To get GCC-like messages, use MSGFORMAT="%f:%y: %c %i: %m". Specifies filename for sytax-definition to be used, if you don't want to use the defaults. Stores some information about the document currently processing in a seperate file to extend functionality. Read the section about Project managment for more details. Note that all documents within a project should use the same project-file. Defines a global attribute. The syntax is equal to , exept that you need no quotes surrounding the value.
Example: DEFINE "hugo:string=hugo was here" Ignore warning message number. Usually, IGNORE needs a numeric argument and can occure multiple. Example:
        IGNORE=21 IGN=18 IGN 3         (ignore warnings #21, #18, #3)
Additionally, you can give IGNORE some special values:
Ignore all non-error messages Ignore all notes Ignore all bad style warnings
All these special values add new messages to the list of messages to be ignored, but do not reset any IGNOREs passed before. Set base mode for syntax check. Legal values are PEDANTIC, NORMAL and RELAXED. Default is NORMAL. This only disables several messages and warnings from the beginning. Any IGNOREs passed before are reseted. Specifies which kind of quotes should be used to surround attribute-values. KEEP keeps the user-kind, DOUBLE tries to assign double quotes (eg. "value"), SINGLE tries to assign single quotes (eg. 'value') and NONE will remove quotes if possible. By default, only the current directory is scanned for files to be included (using the CLI option or the special tags or ). This option adds a directory to the list of directories to search for include files. Display several status messages (output goes to stderr). Legal flags are:
  • QUIET: no status messages
  • LINE: display name and line of file currently processing Included files are also displayed. After processing a file, the filename and the total number of lines remain visible.
  • VERSION: display program title and version
  • VERBOSE: enable verbose status messages; this includes the information displayed during the processing of and some details about images, if has also been enabled.
  • FULL: enable all status messages
The above flags can be combined by separating them with a , eg STATUS=line|version, exept for QUIET and FULL Strip some specific tags from document. You can specify a list of tags which is a string, that contains all tags that should be stripped, sepparated by a .
See also and . Replace all icon entities by images that must be available from the base URI specified. If this URI contains an , it will be substituted by the icon name. For example, with ICONBASE=:icons/*.gif, the entity &back; is replaced by IMG SRC=":icons/back.gif" ALT="back". Note that this argument does not denote a directory, but an URI. It's recommended to use an .

Switches

Display a short help message and exit. Display a short version of the GNU General Public License and exit. Strip redundant linefeeds and white-spaces from output. If you've compiled in debug-mode, it will send lots of information to . Otherwise, this option is equivalent to STATUS=FULL. Get width and height of images and set corresponding attributes WIDTH and HEIGHT with these values; Uses ANSI-sequences to make messages more readable. This option is recommended to be used by people who are not smart enough to integrate in some of the existing project-managment environments. Replace special characters with their entities (eg ü becomes &uuml). Replace double-quotes (") found in the text by &quot;. This does not affect quotes used inside attribute-values. Replace special characters &, < and > with their entities (&amp;, &lt; and &gt;) if they are surrounded by white-spaces. Strip bad white spaces that would have caused message #78 or #79; this will not strip those wich cause message #3. The main advantage of this switch is that it allows you to write well structured macros. Strip all SGML-comments from input. Strip tags which refer to an external URI.

Exit Code

The exit-code returns to the CLI depends on the messages and errors that have been displayed during runtime.

The version for AmigaOS returns

  • 0 on success,
  • 5 if warnings occured,
  • 10 if errors showed up (also for errors in args) and
  • 20 if fatal errors happned (also for out-of-resources).
For other systems, values like 0/0/1/2 are used instead.